//
//  GMVoiceRecoderView.h
//  Gmall
//
//  Created by yemeihua on 15/8/11.
//  Copyright (c) 2015年 Gmall. All rights reserved.
//

#import <UIKit/UIKit.h>

typedef NS_ENUM(NSInteger, GMVoiceRecoderViewState)
{
    GMVoiceRecoderViewStateRecording = 0,
    GMVoiceRecoderViewStateCanCancel = 1,
    GMVoiceRecoderViewStateWarn = 2,
};

@interface GMVoiceRecordView : UIView

@property (nonatomic,readonly) NSTimeInterval duration;
@property (nonatomic) GMVoiceRecoderViewState state;
@property (nonatomic,readonly) NSString *outputFilePath;

- (void)startRecodeInView:(UIView *)view;

- (void)stop;

- (void)cancel;

@end
